package com.pet.entity;

import com.baomidou.mybatisplus.annotation.*;
import lombok.Data;

import java.io.Serializable;

/**
 * 宠物走失信息表

 * @TableName pet_lost
 */
@TableName(value ="pet_lost")
@Data
public class PetLost implements Serializable {
    /**
     * id
     */
    @TableId(value = "lost_id",type = IdType.AUTO)//在自增主键的变量加上即可
    private Integer lostId;

    /**
     * 丢失宠物名称
     */
    @TableField(value = "lost_name")
    private String lostName;

    /**
     * 丢失宠物种类
     */
    @TableField(value = "lost_category")
    private String lostCategory;

    /**
     * 丢失宠物性别
     */
    @TableField(value = "lost_sex")
    private String lostSex;

    /**
     * 丢失宠物联系人
     */
    @TableField(value = "lost_contact")
    private String lostContact;

    /**
     * 丢失宠物联系方式
     */
    @TableField(value = "lost_contact_num")
    private Integer lostContactNum;

    /**
     * 丢失宠物找回状态
     */
    @TableField(value = "lost_status")
    private String lostStatus;

    /**
     * 0未删除1已删除
     */
    @TableLogic
    @TableField(value = "is_delete", fill = FieldFill.INSERT)
    private Integer isDelete;

    private static final long serialVersionUID = 1L;

    /**
     * id
     */
    public Integer getLostId() {
        return lostId;
    }

    /**
     * id
     */
    public void setLostId(Integer lostId) {
        this.lostId = lostId;
    }

    /**
     * 丢失宠物名称
     */
    public String getLostName() {
        return lostName;
    }

    /**
     * 丢失宠物名称
     */
    public void setLostName(String lostName) {
        this.lostName = lostName;
    }

    /**
     * 丢失宠物种类
     */
    public String getLostCategory() {
        return lostCategory;
    }

    /**
     * 丢失宠物种类
     */
    public void setLostCategory(String lostCategory) {
        this.lostCategory = lostCategory;
    }

    /**
     * 丢失宠物性别
     */
    public String getLostSex() {
        return lostSex;
    }

    /**
     * 丢失宠物性别
     */
    public void setLostSex(String lostSex) {
        this.lostSex = lostSex;
    }

    /**
     * 丢失宠物联系人
     */
    public String getLostContact() {
        return lostContact;
    }

    /**
     * 丢失宠物联系人
     */
    public void setLostContact(String lostContact) {
        this.lostContact = lostContact;
    }

    /**
     * 丢失宠物联系方式
     */
    public Integer getLostContactNum() {
        return lostContactNum;
    }

    /**
     * 丢失宠物联系方式
     */
    public void setLostContactNum(Integer lostContactNum) {
        this.lostContactNum = lostContactNum;
    }

    /**
     * 丢失宠物找回状态
     */
    public String getLostStatus() {
        return lostStatus;
    }

    /**
     * 丢失宠物找回状态
     */
    public void setLostStatus(String lostStatus) {
        this.lostStatus = lostStatus;
    }

    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        PetLost other = (PetLost) that;
        return (this.getLostId() == null ? other.getLostId() == null : this.getLostId().equals(other.getLostId()))
            && (this.getLostName() == null ? other.getLostName() == null : this.getLostName().equals(other.getLostName()))
            && (this.getLostCategory() == null ? other.getLostCategory() == null : this.getLostCategory().equals(other.getLostCategory()))
            && (this.getLostSex() == null ? other.getLostSex() == null : this.getLostSex().equals(other.getLostSex()))
            && (this.getLostContact() == null ? other.getLostContact() == null : this.getLostContact().equals(other.getLostContact()))
            && (this.getLostContactNum() == null ? other.getLostContactNum() == null : this.getLostContactNum().equals(other.getLostContactNum()))
            && (this.getLostStatus() == null ? other.getLostStatus() == null : this.getLostStatus().equals(other.getLostStatus()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getLostId() == null) ? 0 : getLostId().hashCode());
        result = prime * result + ((getLostName() == null) ? 0 : getLostName().hashCode());
        result = prime * result + ((getLostCategory() == null) ? 0 : getLostCategory().hashCode());
        result = prime * result + ((getLostSex() == null) ? 0 : getLostSex().hashCode());
        result = prime * result + ((getLostContact() == null) ? 0 : getLostContact().hashCode());
        result = prime * result + ((getLostContactNum() == null) ? 0 : getLostContactNum().hashCode());
        result = prime * result + ((getLostStatus() == null) ? 0 : getLostStatus().hashCode());
        return result;
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", lostId=").append(lostId);
        sb.append(", lostName=").append(lostName);
        sb.append(", lostCategory=").append(lostCategory);
        sb.append(", lostSex=").append(lostSex);
        sb.append(", lostContact=").append(lostContact);
        sb.append(", lostContactNum=").append(lostContactNum);
        sb.append(", lostStatus=").append(lostStatus);
        sb.append(", serialVersionUID=").append(serialVersionUID);
        sb.append("]");
        return sb.toString();
    }
}